<%--
  Created by IntelliJ IDEA.
  User: VULCAN
  Date: 2021/8/16
  Time: 12:35
  To change this template use File | Settings | File Templates.
--%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
    <link href="${pageContext.request.contextPath}/bootstrap/css/bootstrap.css" rel="stylesheet">
    <script src="${pageContext.request.contextPath}/jquery/jquery-3.3.1.js"></script>
    <script src="${pageContext.request.contextPath}/bootstrap/js/bootstrap.js"></script>
</head>
<body>
<div class="collapse" id="collapseExample" style="display: block">
    <div class="card card-body">
        <div class="page-container">
            <table class="table" id="book_table">
                <h3 align="center">用户订单</h3>
                <thead>
                <tr>
                    <th>用户名</th>
                    <th>订单号</th>
                    <th>商品名</th>
                    <th>商品单价</th>
                    <th>商品数量</th>
                    <th>商品总价</th>
                    <th>订单状态</th>
                </tr>
                </thead>
                <tbody>
                <c:forEach items="${orderList}" var="one">
                <tr>
                    <td>${one.users.username}</td>
                    <td>${one.orderNumber}</td>
                    <td>${one.goods.goodsName}</td>
                    <td>${one.goods.goodPrice}</td>
                    <td>1</td>
                    <td>${one.goods.goodPrice*1}</td>
                    <td>
                        <c:choose>
                            <c:when test="${one.status == 0}">未付款</c:when>
                            <c:when test="${one.status == 1}">未发货</c:when>
                            <c:when test="${one.status == 2}">交易完成</c:when>
                        </c:choose>
                    </td>
                </tr>
                </tbody>
                </c:forEach>
            </table>
        </div>
    </div>
</div>





<script>

</script>
</body>
</html>
